<?
include_once ($_SERVER['DOCUMENT_ROOT']."/inc/conn.inc.php");
include_once ($_SERVER['DOCUMENT_ROOT']."/inc/function.inc.php");
include_once ($_SERVER['DOCUMENT_ROOT']."/lib/Curl.php");


//$homepage = fopen('../logs/log4php-'.date("Ymd-H").".log");

$handle = fopen('../logs/log4php-daily_'.date("Ymd").".log", "r");
$contents =  stream_get_contents($handle);
fclose($handle);

$contents = nl2br($contents);
$divContent = explode("##<br />",$contents);
echo "<table border=\"1\" cellpadding=\"0\" cellspacing=\"0\">\n";
for ($c=count($divContent); $c>=0; $c--)
{
	if (strlen($divContent[$c])>10)
	{
		$divVal = explode("[#]",$divContent[$c]);
		echo "<tr style=\"font-size:10pt;height:25px \">\n";
		for ($k=0; $k<count($divVal); $k++)
		{
			echo "<td>" .str_replace("<br /><br />", "<br />",$divVal[$k]) ."</td>";
		}	
		echo "\n</tr>\n";
	}
}
echo "</table>"
?>